﻿@using Web.Models
@model News
@{
    ViewBag.Title = Model.Title;
    List<Category> categoryList = ViewBag.CategoryList ?? new List<Category>();
}

@section head{
    <link href="~/content/css/about.min.css" rel="stylesheet" />
    <link href="~/content/css/about.mobile.min.css" rel="stylesheet" />
}
    <div class="banner"></div>
<div class="about-main" style="overflow: hidden">
    <div class="nav">
        <ul>
            @foreach (var item in categoryList)
            {
                <li @Html.Raw(item.Id == ViewBag.CategoryId ? "class=\"active\"" : "")>
                    <a href="@Url.Action("Index",new{CategoryId=item.Id})">@item.CategoryName</a>
                </li>
            }
        </ul>
    </div>
    
    <div class="news-content">
        <div class="titlebox">
            <div class="title">@Html.Raw(Model.Title)</div>
            <div class="time">@Model.CreateTime.ToString("yyy-MM-dd")</div>
        </div>
        
        <div class="contentbox">
            @Html.Raw(Model.Profile)
        </div>
    </div>
</div>